<?php
namespace app\common\logic;
use smssdk\Sms;
use think\Controller;



class SmsLogic extends Controller
{
    public function mobilesend($phone,$moban){
        $accessKeyId='LTAIc2rnHp53SkQF';
        $accessSecret='dVyjVLHSpgO8jenQYIXKVMBXoEOq1D';
        $signName='足道天下';
        $sms=new Sms($accessKeyId,$accessSecret,$signName);

        if($moban==1) {
            $sms->setTemplateCode('SMS_137345064');
        }else if($moban==2){
            $sms->setTemplateCode('SMS_150866054');

        }else if($moban==3){
            $sms->setTemplateCode('SMS_138077208');

        }else if($moban==4){
            $sms->setTemplateCode('SMS_140110176');
        }

        return $sms->sendCode($phone,$moban);

    }
}